Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update sbt-scalafix, scalafix-core to 0.10.0 #17

Merged
merged 2 commits into from
Apr 8, 2022

Conversation

scala-steward-bot
Copy link
Contributor

Updates

from 0.9.34 to 0.10.0.
GitHub Release Notes - Version Diff

I'll automatically update this PR to resolve conflicts as long as you don't change it yourself.

If you'd like to skip this version, you can just close this PR. If you have any feedback, just mention me in the comments below.

Configure Scala Steward for your repository with a .scala-steward.conf file.

Have a fantastic day writing Scala!

Ignore future updates

Add this to your .scala-steward.conf file to ignore future updates of this dependency:

updates.ignore = [ { groupId = "ch.epfl.scala" } ]

labels: library-update, early-semver-major, semver-spec-minor, commit-count:1

@bjaglin
Copy link

bjaglin commented Apr 8, 2022

@bjaglin
Copy link

bjaglin commented Apr 8, 2022

FWIW, a hack like does the trick, to favor Versions from scalafix-core over sbt-scalafix considering that:

 lazy val plugin = project
   .in(file("plugin"))
   .enablePlugins(ScriptedPlugin)
   .dependsOn(LocalProject("common2_12"), LocalProject("fix2_12") % Test)
   .settings(
     commonSettings,
     description := "find unused code sbt plugin",
     scalapropsSettings,
     scalapropsVersion := "0.9.0",
     addSbtPlugin("ch.epfl.scala" % "sbt-scalafix" % _root_.scalafix.sbt.BuildInfo.scalafixVersion),
     scriptedLaunchOpts += "-Dplugin.version=" + version.value,
     scriptedBufferLog := false,
     sbtPlugin := true,
     name := "unused-code-plugin",
     moduleName := "unused-code-plugin",
+    Test / dependencyClasspath := (Test / dependencyClasspath).value.reverse,
   )

@xuwei-k xuwei-k merged commit 2e09b98 into xuwei-k:main Apr 8, 2022
@bjaglin
Copy link

bjaglin commented Apr 8, 2022

By the way, thanks for this fascinating project @xuwei-k! I didn't have a deep look at the implementation, but I was wondering if you considered implementing unusedCode as a scalafix rule itself (which would just collect the data consumed by WarnUnusedCode & RemoveUnusedCode) for more portability? Users would then just need to run scalafix DetectUnusedCode WarnUnusedCode without the need for a separate plugin.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants